//
//  YJWPicViewController.m
//  百思不得骑姐
//
//  Created by YJW on 16/11/27.
//  Copyright © 2016年 yijiang. All rights reserved.
//

#import "YJWPicViewController.h"

@interface YJWPicViewController ()

@end

@implementation YJWPicViewController

- (void)viewDidLoad {
    [super viewDidLoad];
  
    //初始化 tableView
    [self setUpTableView];
}

/**
 初始化 tableView
 */
-(void)setUpTableView
{
    //设置内边距
    CGFloat top = YJWTitlesViewH + YJWTitlesViewY;
    CGFloat bottom = self.tabBarController.tabBar.height;
    self.tableView.contentInset = UIEdgeInsetsMake(top, 0, bottom, 0);
    //设置导航条的内边距
    self.tableView.scrollIndicatorInsets = self.tableView.contentInset;
    
    
}


- (void)didReceiveMemoryWarning {
    [super didReceiveMemoryWarning];
    // Dispose of any resources that can be recreated.
}

#pragma mark - <UITableViewDataSource>
-(NSInteger)tableView:(UITableView *)tableView numberOfRowsInSection:(NSInteger)section
{
    return 50;
}

-(UITableViewCell *)tableView:(UITableView *)tableView cellForRowAtIndexPath:(NSIndexPath *)indexPath
{
    static NSString *reID = @"cell";
    
    UITableViewCell *cell = [tableView dequeueReusableCellWithIdentifier:reID];
    
    if (cell == nil) {
        cell = [[UITableViewCell alloc] initWithStyle:UITableViewCellStyleDefault reuseIdentifier:reID];
    }
    
    cell.textLabel.text = [NSString stringWithFormat:@"%@-----%zd",[self class],indexPath.row];
    
    return cell;
}

@end
